import 'package:flutter/material.dart';
import 'package:lib_core/lib_core.dart';
import 'package:lib_ui/gen/assets.gen.dart';
import 'package:lib_ui/gen/colors.gen.dart';
import 'package:lib_ui/lib_ui.dart';
import 'package:lib_ui/utils/ld_font.dart';
import 'package:lib_ui/widget/main_button.dart';

/// 一个测试底部弹窗
class BoostTestBottomSheet extends PagerSheet {
  @override
  double? height = Get.height * 0.3;

  @override
  Widget initialWidget = ClipRRect(
    borderRadius: const BorderRadius.only(
      topLeft: Radius.circular(21),
      topRight: Radius.circular(21),
    ),
    child: Container(
      color: Colors.white,
      padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 20),
      child: Column(
        children: [
          Row(
            mainAxisAlignment: MainAxisAlignment.spaceBetween,
            children: [
              Text(
                '底部测试弹窗',
                style: LDFont.medium(fontSize: 17, color: ColorName.textPrimary),
              ),
              GestureDetector(
                onTap: BoostNavigator.instance.pop,
                child: UIAssets.images.icClose.svg(width: 30, height: 30),
              ),
            ],
          ),
          Container(
            width: double.infinity,
            margin: const EdgeInsets.only(top: 22),
            child: MainButton(
              text: '确定',
              type: MainButtonType.primary,
              onClick: () {},
            ),
          ),
        ],
      ),
    ),
  );
}
